Component({
    properties: {
        defaultType: {
            type: [ Number, Object, String ]
        }
    },
    data: {
        show: !1,
        active: 1
    },
    observers: {
        defaultType: function() {
            this.setData({
                active: this.data.defaultType
            });
        }
    },
    methods: {
        showPopup: function() {
            this.setData({
                show: !this.data.show
            });
        },
        selectType: function(t) {
            var e = t.currentTarget.dataset.type;
            this.setData({
                active: e
            });
        },
        confirmType: function() {
            this.showPopup(), this.triggerEvent("confirmType", this.data.active);
        }
    }
});